import Vue from 'vue'
import VueRouter from 'vue-router'

// import Zyw from '@/view/zyw/zyw.vue';

import HelloWorld from '@/components/HelloWorld'
import StudyDl from '@/view/practiceDl/study'
import StudyHyl from '@/view/practiceHyl/study'
import StudyZyw from '@/view/practiceZyw/study'
Vue.use(VueRouter)

const routes = [
    { path: '/', component: HelloWorld },

    {
        path: '/dl',
        component: StudyDl,
        children: [
          {path:'Tex',component:()=>import('@/view/practiceDl/dl/tex')},
          {path:'Table',component:()=>import('@/view/practiceDl/dl/table')},
          {path:'Form',component:()=>import('@/view/practiceDl/dl/form')},
          {
            path: 'DlA',
            component: () => import('@/view/practiceDl/dl/dayThree/A'),
          },
          {
            path: 'DlB',
            component: () => import('@/view/practiceDl/dl/dayThree/B'),
            children: [
              {
                path: '',
                component: () => import('@/view/practiceDl/dl/dayThree/C'),
              },
            ],
            // name: 'PageB',
          },
        ],
      },

    { path: '/hyl', component: StudyHyl },
    {
        path: '/zyw', component: StudyZyw,
        children: [{
            path: 'zywlll',
            component: () => import('@/view/practiceZyw/zyw/zyw.vue')
        },
        {
            path:'zywTable',
            component:() => import('@/view/practiceZyw/zyw/ts.vue') 
        },
        {
            path:'zywMeg',
            component:() => import('@/view/practiceZyw/zyw/messagebox.vue')
        },
        {
            path:'zywForm',
            component:() => import('@/view/practiceZyw/zyw/myform.vue')
        },
    ]
    },
    {
        path: '/zywA',
        component: () => import('@/view/practiceZyw/zyw/zywrouter/zywA.vue')
    },
    {
        name: 'zywB',
        path: '/zywB',
        component: () => import('@/view/practiceZyw/zyw/zywrouter/zywB'),
        children: [
            {
                path: '',
                name: 'zzz',
                component: () => import('@/view/practiceZyw/zyw/zywrouter/zywC')
            }

        ]
    }
]

const router = new VueRouter({
  mode: 'history',
  base: process.env.BASE_URL,
  routes,
})

export default router
